<!DOCTYPE html>
<html>
    
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
        <title>query.order</title>
        <script>
            window.$$path = location.protocol + "//" + location.host;
            document.write('<script src="' + $$path + '/mass_merge.js"><\/script>');
            document.write('<script src="' + $$path + '/doc/scripts/common.js"><\/script>');
        </script>
        <style type="text/css">
            ul{
                list-style-image: url(../public/images/li.gif)
            }
            .list {
                color:#FF6363;
                font-weight:bolder;
            }
            table.clicktable {
                border-collapse:collapse;
                border:#8a6100 1px solid;
            }
            table.clicktable th{
                border:#8a6100 2px solid;
                border-color:  #ffe3a4 #ffe3a4 #8a6100 #8a6100;
                color: #ffff00;
                background:#e19d00;
            }
            table.clicktable td{
                border:#8a6100 1px   inset;
                background:#EEE8AA;
                color:#000;
            }
            table.clicktable tr.even td{
                background:#FF7F50;
                color:#8B4513;
            }
        </style>
        <script type="text/javascript">
            $(function(){
                $("body").delegate(".clicktable tbody td","click",function(){
                    var input =  $("input[type=checkbox]:first")
                    if(input.length){
                        input[0].indeterminate = true;
                    }
                    var code = $.String.unescapeHTML( this.innerHTML )
                    $.parseJS( code );
                });
            })
        </script>
    </head>
    
    <body>
        <article>
            <p>位置伪类，:first, :last, :even, :odd, :eq(n), :gt(n), :lt(n)。</p>
            <p>它是根据上一个表达式得到的节点集合的索引值来选择元素的。如"div:first",它会得到一组DIV元素，然后取得第一个返回。</p>
            <p>此种伪类是非标准的，因此不建议使用。使用mass实例的同名方法，效果一致的。</p>
            <fieldset>
                <legend>例子</legend>
                <table class="clicktable" cellspacing="0" width="700" rules="cols">
                    <thead>
                        <tr>
                            <th>请点击下面表格</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>$("li:first").css("bgc","#FF9");</td>
                        </tr>
                        <tr>
                            <td>$("li:last").css("bgc","#6495ED");</td>
                        </tr>
                        <tr>
                            <td>$("li:even").css("bgc","#FF1493");</td>
                        </tr>
                        <tr>
                            <td>$("li:odd").css("bgc","#800080");</td>
                        </tr>
                        <tr>
                            <td>$("li:lt(4)").css("bgc","#E9967A");</td>
                        </tr>
                        <tr>
                            <td>$("li:gt(5)").css("bgc","#98FB98");</td>
                        </tr>
                        <tr>
                            <td>$("li:eq(3)").css("bgc","#FFF0F5");</td>
                        </tr>
                    </tbody>
                </table>
                <pre class="brush:xml;gutter:false;toolbar:false">

 <ul>
        <li>list item 1</li>
        <li>list item 2</li>
        <li>list item 3</li>
        <li>list item 4</li>
        <li>list item 5</li>
    </ul>
    <ul>
        <li>list item 6</li>
        <li>list item 7</li>
        <li>list item 8</li>
        <li>list item 9</li>
        <li>list item 10</li>
    </ul>
    
</pre>
                <ul>
                    <li>list item 1</li>
                    <li>list item 2</li>
                    <li>list item 3</li>
                    <li>list item 4</li>
                    <li>list item 5</li>
                </ul>
                <ul>
                    <li>list item 6</li>
                    <li>list item 7</li>
                    <li>list item 8</li>
                    <li>list item 9</li>
                    <li>list item 10</li>
                </ul>
            </fieldset>
        </article>
    </body>

</html>